﻿using System.Collections.Generic;
using StockholmsStad.Web.UI.Class.Interfaces;
using StockholmsStad.Web.UI.UIServiceReference;

namespace StockholmsStad.Web.UI.Class.Controller
{
    /// <summary>
    /// MVC controller för vanliga frågor och svar-sidan. 
    /// </summary>
    public class FAQController
    {
        private readonly IFAQModel faqModel;
        private readonly ILoginModel loginModel;

        /// <summary>
        /// 
        /// </summary>
        /// <param name="faqModel"></param>
        /// <param name="loginModel"></param>
        public FAQController(IFAQModel faqModel, ILoginModel loginModel)
        {
            this.faqModel = faqModel;
            this.loginModel = loginModel;
        }

        /// <summary>
        /// 
        /// </summary>
        /// <returns></returns>
        public IList<InformationText> GetTexts()
        {
            return faqModel.GetTexts(loginModel.User, (int)UIServiceReference.InformationTextType.FAQ); 
        }
    }
}
